// =====================
// The cube pixel shader
// =====================

// The texture sampler 
sampler TextureSampler	: register(s0);

// The pixel shader input structure
struct PS_INPUT
{
	float4 position : POSITION;
	float4 Color : COLOR0;	
	float2 TexCoord : TEXCOORD0;
};

// The pixel shader output structure
struct PS_OUTPUT
{
	float4 Color	: COLOR0;		// Output color of the pixel
};

// Our pixel shader
PS_OUTPUT MainPixelShader(PS_INPUT In)
{
	PS_OUTPUT Result;
	

	
	float4 TexColor = tex2D(TextureSampler, In.TexCoord);

	Result.Color = TexColor; 
	//Result.Color = In.Color;
	Result.Color.rgb += In.Color.rgb;
	Result.Color.rgb/=2.0f;
	
	
	return Result;
}